<!DOCTYPE html>
<html lang="">
	<head>
		<meta charset="utf-8">
		<script src="https://apps.bdimg.com/libs/jquery/2.1.4/jquery.min.js"></script>
		<meta http-equiv="X-UA-Compatible" content="IE=edge">
		<link rel="icon" href="">
		<title></title>
	</head>
	<body>
		<noscript>
			<strong>We're sorry but <%= htmlWebpackPlugin.options.title %> doesn't work properly without JavaScript
				enabled. Please enable it to continue.</strong>
		</noscript>
		<div id="app"></div>
		<!-- built files will be auto injected -->
	</body>
	<script>
		var linkss = document.getElementsByTagName('link')[0];
		if (localStorage.getItem('siteTitle')) {
			document.title = localStorage.getItem('siteTitle');
		}
		if (localStorage.getItem('siteIco')) {
			linkss.href = localStorage.getItem('siteIco');
		}
		// 获取网站配置信息
		$.ajax({
			url: 'http://43.198.233.28/m/new_system_config',
			type: 'get',
			data: {},
			dataType: 'json', // 用于设置响应体的类型 注意 跟 data 参数没关系！！！
			headers: {
				'Content-Type': 'application/x-www-form-urlencoded'
			},
			success: function(res) {
				if (res.status.errorCode == 0) {
					console.log(res);
					document.title = res.data.site_title;
					localStorage.setItem('siteTitle', res.data.site_title)
					localStorage.setItem('siteIco', 'https://hkico.s3.ap-east-1.amazonaws.com/HK.ico')
					linkss.href = 'https://hkico.s3.ap-east-1.amazonaws.com/HK.ico';
				}
			}
		});
	</script>
</html>